package com.itfitness.mchart.bean;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

/**
 * @ProjectName: MChart
 * @Package: com.itfitness.mchart.bean
 * @ClassName: InviteNotifyBean
 * @Description: java类作用描述 ：邀请通知
 * @Author: 作者名：lml
 * @CreateDate: 2019/4/25 11:06
 * @UpdateUser: 更新者：
 * @UpdateDate: 2019/4/25 11:06
 * @UpdateRemark: 更新说明：
 * @Version: 1.0
 */
@DatabaseTable(tableName = "invitenotify")
public class InviteNotifyBean {
    public static final int INVITETYPE_CONTACT = 1;//好友
    public static final int INVITETYPE_GROUP = 2;//群组
    /**
     * 邀请通知信息枚举
     */
    public enum InviteNotifyStatus{
        CONTACT_CONTACTINVITED,//收到好友邀请
        CONTACT_FRIENDREQUESTACCEPTED,//好友请求被同意
        CONTACT_FRIENDREQUESTDECLINED,//好友请求被拒绝
        CONTACT_ACCEPTEDFRIENDREQUEST,//同意好友请求
        CONTACT_DECLINEDEDFRIENDREQUEST,//拒绝好友请求
        GROUP_INVITATIONRECEIVED,//接收到群组加入邀请
        GROUP_INVITATIONACCEPTED,//群组邀请被同意
        GROUP_INVITATIONDECLINED,//群组邀请被拒绝
        GROUP_ACCEPTEDINVITATION,//已同意群组邀请
        GROUP_APPLYJOIN,//用户申请加入群
        GROUP_DECLINEDINVITATION,//已拒绝群组邀请
        GROUP_AUTOACCEPTINVITATIONFROMGROUP//自动加入群
    }
    // 定义字段在数据库中的字段名
    public static final String COLUMNNAME_ID = "id";
    public static final String COLUMNNAME_USERNAMWE = "uname";//用户名
    public static final String COLUMNNAME_GROUPID = "gid";//群id
    public static final String COLUMNNAME_GROUPNAME = "gname";//群名称
    public static final String COLUMNNAME_INVITE = "invite";//邀请人
    public static final String COLUMNNAME_TYPE = "type";//邀请类型
    public static final String COLUMNNAME_STATUS = "status";//邀请状态

    @DatabaseField(generatedId = true)
    private int id;
    @DatabaseField(columnName = COLUMNNAME_USERNAMWE)
    private String username;
    @DatabaseField(columnName = COLUMNNAME_GROUPID)
    private String groupid;
    @DatabaseField(columnName = COLUMNNAME_GROUPNAME)
    private String groupname;
    @DatabaseField(columnName = COLUMNNAME_INVITE)
    private String invite;
    @DatabaseField(columnName = COLUMNNAME_STATUS)
    private InviteNotifyStatus status;
    @DatabaseField(columnName = COLUMNNAME_TYPE)
    private int type;

    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getGroupid() {
        return groupid;
    }

    public void setGroupid(String groupid) {
        this.groupid = groupid;
    }

    public String getGroupname() {
        return groupname;
    }

    public void setGroupname(String groupname) {
        this.groupname = groupname;
    }

    public String getInvite() {
        return invite;
    }

    public void setInvite(String invite) {
        this.invite = invite;
    }

    public InviteNotifyStatus getStatus() {
        return status;
    }

    public void setStatus(InviteNotifyStatus status) {
        this.status = status;
    }

    public InviteNotifyBean(int type,String username, String groupid, String groupname, String invite, InviteNotifyStatus status) {
        this.type = type;
        this.username = username;
        this.groupid = groupid;
        this.groupname = groupname;
        this.invite = invite;
        this.status = status;
    }

    public InviteNotifyBean() {
    }
}
